use 5.006;
use strict;
use warnings;
use Module::Build;

my $builder = Module::Build->new(
    module_name         => 'AlienArena::Server',
    license             => 'perl',
    dist_author         => q{Mark A. Jensen <maj -at- fortinbras -dot- us>},
    dist_version_from   => 'lib/AlienArena/Server.pm',
    build_requires => {
        'Test::More' => 0,
    },
    requires => {
        'perl' => 5.006,
	'POE'  => 0,
	'POE::Component::Client::Rcon' => 0,
	'Time::HiRes' => 0,
	'Carp' => 0,
	'Exporter' => 0
    },
    add_to_cleanup      => [ 'AAServer-*' ],
    create_makefile_pl => 'traditional',
);
if ($builder->y_n('Do you wish to run live server tests? (You will be prompted for server info.)', 'n')) {
 $builder->notes('test_host',
		 $builder->prompt('Server ip: ','127.0.0.1'));
 $builder->notes('test_port',
		 $builder->prompt('Server port: ','27901'));
 $builder->notes('test_pass',
		 $builder->prompt('Server rcon password: ',''))
}
$builder->create_build_script();
